package fox.framework.rpc.client.node;

/**
 * @author cuichao
 * @Description: RootRpcNode
 * @Date: create in 2021/2/5 19:54
 */
public class RootRpcNode extends RpcNode {

    public RootRpcNode(RpcMetadata metadata,String address) {
        String[] split = address.split(":");
        if(split.length == 2){
            this.host = split[0];
            this.port = Integer.valueOf(split[1]);
        }else {
            this.host = split[0];
            this.port = 80;
        }
        this.path = metadata.metaspace();
        this.address = address;
    }
}
